<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<errors>
{foreach key=file item=issues from=$all}
    <file name="{$file}">
    {if count($issues.warnings)}
    {section name=warnings loop=$issues.warnings}
    <warning num="{$issues.warnings[warnings].num}" line="{$issues.warnings[warnings].name|replace:'Warning':'-'}">
    <![CDATA[{$issues.warnings[warnings].listing}]]>
    </warning>
    {/section}
    {/if}
    {if count($issues.errors)}
    {section name=errors loop=$issues.errors}
    <error num="{$issues.errors[errors].num}" line="{$issues.errors[errors].name}">
    <![CDATA[{$issues.errors[errors].listing}]]>
    </error>
    {/section}
    {/if}
    </file>
{/foreach}
</errors>